Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce transcription protocol #194

Merged
merged 13 commits into from
Apr 27, 2024
Merged

Introduce transcription protocol #194

merged 13 commits into from
Apr 27, 2024

Conversation

keepingitneil
Copy link
Contributor

No description provided.

Copy link
Member

@davidzhao davidzhao left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm!

thanks for fixing the CI too

@@ -117,6 +131,42 @@ async def publish_data(
if cb.publish_data.error:
raise PublishDataError(cb.publish_data.error)

async def publish_transcription(
self,
participant_identity: str,
Copy link
Member

@theomonnom theomonnom Apr 27, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would be more comfortable creating a Transcription structure here.
On the agents API, we will need to return a Transcription, and I don't think this should be defined inside agents.

publish_transcription accepting a "Transcription" seems OK to me

Also this will be needed for the "on_transcription_received" event

Copy link
Member

@theomonnom theomonnom left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm also wondering if start_time and end_time should be float on the Python side.
To respect the time.time() format.

Maybe we could automatically do the conversion?

@@ -0,0 +1,10 @@
from dataclasses import dataclass


Copy link
Member

@theomonnom theomonnom Apr 27, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add it here? (Transcription struct)

@keepingitneil
Copy link
Contributor Author

@theomonnom re: float. I think we should keep it int because the clock being used will be the frame clock. Although I'm wondering if we should specify units in the transcription protocol now: start_time_us ?

@theomonnom
Copy link
Member

let's mb wait for a release tho?

@keepingitneil keepingitneil merged commit c275775 into main Apr 27, 2024
11 checks passed
@keepingitneil keepingitneil deleted the neil/transcription branch April 27, 2024 16:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants